import { http } from "@/utils/http";

type ResultTable = {
  total?: number;
  data?: Array<any>;
};

//查询配额
export const quotaquery = (data?: object) => {
  return http.request<ResultTable>("post", `/energy/quota/query`, {
    data
  });
};
//新增配额
export const quotasave = (data?: object) => {
  return http.request<ResultTable>("post", `/energy/quota/save`, {
    data
  });
};
//修改配额
export const quotaedit = (data?: object) => {
  return http.request<ResultTable>("post", `/energy/quota/edit`, {
    data
  });
};
//删除配额
export const quotadelete = (data?: object) => {
  return http.request<ResultTable>("post", `/energy/quota/delete`, {
    data
  });
};
//查看配额详情
export const quotadetail = (data?: object) => {
  return http.request<ResultTable>("post", `/energy/quota/detail`, {
    data
  });
};

//试算
export const quotatrial = (data?: object) => {
  return http.request<ResultTable>("post", `/energy/quota/trial`, {
    data
  });
};

//配额监控
export const quotamonitor = (data?: object) => {
  return http.request<any>("post", `/energy/quota/monitor`, {
    data
  });
};
